using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using DevExpress.XtraReports.UI;

namespace p301.Reports.ZapKons
{
    public partial class PrintZapKonsNeprish : DevExpress.XtraReports.UI.XtraReport
    {
        int _iNPP = 1;
        string _textN_RAB = "";
        
        public PrintZapKonsNeprish()
        {
            InitializeComponent();
        }

        public void OpenSubReport(dsZapKons ds)
        {
            this.DataSource = ds;
        }

        private void _NPP_BeforePrint(object sender, System.Drawing.Printing.PrintEventArgs e)
        {
            if (_textN_RAB != _N_RAB.Text)
            {
                _iNPP = 1;
                _textN_RAB = _N_RAB.Text; 
            }
            _NPP.Text = _iNPP.ToString();
            _iNPP++;
        }

    }
}
